<%@ page language="java" contentType="text/html; charset=ISO-8859-1"
    pageEncoding="ISO-8859-1" import="support.*, java.util.*"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<html>
<head>
	<title>Graduate School Application - Specialization</title>
	<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
	<link rel="stylesheet" type="text/css" href="../resource/styleCSS.css" /> 
	<link rel="stylesheet" type="text/css" href="../resource/columnCSS.css" />	
</head>
<body>
	<%
		// Get Vector of specializations
		support s = new support(); 
 		String path = config.getServletContext().getRealPath("specializations.txt");
		Vector specializations = s.getCountries(path);
		
		// Get session information
		String fname = (String)session.getAttribute("fname");
		String lname = (String)session.getAttribute("lname");
		String mname = (String)session.getAttribute("mname");
		
		String citizen = (String)session.getAttribute("citizen");
		String residence = (String)session.getAttribute("residence");
		
		String address = (String)session.getAttribute("address"); 
		String city = (String)session.getAttribute("city");
		String state = (String)session.getAttribute("state");
		Integer zipcode = (Integer)session.getAttribute("zipcode");
		Integer areacode = (Integer)session.getAttribute("areacode");
		Integer number = (Integer)session.getAttribute("number");
		Integer countrycode = (Integer)session.getAttribute("countrycode");
		Boolean domestic = (Boolean)session.getAttribute("domestic");
		
	%>
	<p class="sansserif">
	<div class="container">
	<div class="center_div">
		<div class="colmask threecol">
		<div class="colmid">
		<div class="colleft">
			<div class="bodycol">
				<p>Applicant: <i><%= fname%> <%= mname%> <%= lname%></i></p> 
				<p>Citizenship: <i><%= citizen%></i></p>
				<p>Country of Residence: <i><%= residence%></i></p> 
				<p>Address: <i><%= address%></i></p>
				<p>City: <i><%= city%></i> 
				<%
					if ( state != null ) {
						out.println("State: <i>" + state + "</i>");
					}
				%>
				Zip Code: <i><%= zipcode%></i></p>
				<p>Telephone: <i><%= areacode %> <%= number%></i>
				<%
					if ( countrycode != null ) {
						out.println("Country Code: <i>" + countrycode + "</i>");
					}
				%>
				</p>
				<p>Domestic: <i><%= domestic%> </i> </p>
				<br>
			</div>
			<div class="sidecol">
				<p><a href="../invalidate.jsp">Logout</a></p>
			</div>
		</div>
		</div>
		</div>
		<div style="clear:both;"></div>
		
		<p><b>Choose Specialization</b> </p>
		<ul class="none">
		<li>
		<form method="GET" action="verificationJSP.jsp">
			<select name="specification">
			<% 
				for(int index = 0; index < specializations.size(); index++) {
					String value = (String)specializations.get(index);
					out.println("<option value=\"" + value + "\">" + value + "</option>");
				}
			%>
			</select>
		   	<input type="submit" value="Submit"/>
		</form>
		</li>
		</ul>
	</div>
	</div>
</body>
</html>